/**
 * 给两个点，构造另外两个点使得四个点构成横平竖直的矩形
 * 分三种情况讨论即可
 */
#include <bits/stdc++.h>
using namespace std;

using llt = long long;
struct _t{
    llt x;
    llt y;
    _t() = default;
    _t(llt a, llt b):x(a),y(b){}
    void input(){
        cin >> x >> y;
    }
};

ostream & operator << (ostream & os, const _t & t){
    return os << t.x << " " << t.y;
}

_t A, B;

void work(){
    A.input(); B.input();
    if(A.x == B.x){
        return (void)(cout << _t(A.x + 1, A.y) << " " << _t(B.x + 1, B.y) << endl);
    }
    if(A.y == B.y){
        return (void)(cout << _t(A.x, A.y + 1) << " " << _t(B.x, B.y + 1) << endl);
    }
    cout << _t(A.x, B.y) << " " << _t(B.x, A.y) << endl;
    return;
}

int main(){
#ifndef ONLINE_JUDGE
    freopen("z.txt", "r", stdin);
#endif
    ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);	
    int nofkase = 1;
    // cin >> nofkase;
    while(nofkase--) work();
	return 0;
}